<?php 
	session_start();	
	include("Coneccion.php");
	$link=conectarse();
	$cotnot=$_POST["id"];
	$cod_user = $_SESSION["usuario"];
	$result = mysql_query("SELECT Titulo FROM noticia where Cod_noticia  = $cotnot;",$link); 
	$row = mysql_fetch_array($result);
	$titulo = $row["Titulo"];
	mysql_query("INSERT INTO bitacora VALUES (NULL,'$cod_user', 'Noticias', '3', '$cotnot', now(), '$titulo');",$link);		
	mysql_query("DELETE FROM noticia where Cod_noticia = $cotnot",$link);		
	echo "<meta http-equiv='refresh' content='4; url=mostrarNoticia.php' />";
?>
<script type="text/javascript">
function validar(){
	alert("Se elimino satisfactoriamente.");
	document.form1.submit();
}
</script>
<BODY >
<TABLE height='100%' cellSpacing=3 cellPadding=0 width=549 align=center bgColor=#ffffff border=0>
  <TBODY>
  <TR>
    <TD vAlign=top width=543 bgColor=#ff0000 height='100'>
      <TABLE height='100%' cellSpacing=1 width=545 align=center border=0>
        <TBODY>
        <TR>
          <TD vAlign=top bgColor=#ffffff height='100' width='541'><DIV align=center>
            <TABLE height='293' cellSpacing=5 width=437 align=center bgColor=#ffffff border=0>
              <TBODY>			  
              <TR>			  
                <TD width=425 bgColor=#ffffff height='200'><div id='muestra'>
                  <p>&nbsp;</p>
                  <div align='center'><img src='eliminar_noticia.png' width='408' height='118'>                  </div>                  
                  <p align='center' class='Estilo4'> 
                  <p align='left' class='Estilo1'>		  </TD>
              </TR>
			  </TBODY></TABLE>
        </DIV></TD></TR></TBODY></TABLE></TD>
</TR></TBODY></TABLE>
</BODY>
</BODY>
